﻿using YAPACS.BusinessObjects.Managements.Exams;
using YAPACS.RisServer.Services.ExtendCells;

namespace YAPACS.RisServer.Abstractions;

public interface ICellFactoryService
{
    /// <summary>
    /// 获取新MultiRowCell
    /// </summary>
    /// <param name="text"></param>
    /// <param name="width"></param>
    /// <returns></returns>
    MultiRowCell NewMultiRowCell(string text, double width,int rowSpan, string textAlign);

    /// <summary>
    /// 获取新RowFlex对象
    /// </summary>
    /// <returns></returns>
    RowFlex NewRowFlex();


    /// <summary>
    /// 获取新文本单元格对象
    /// </summary>
    /// <param name="text"></param>
    /// <param name="width"></param>
    /// <param name="rowSpan"></param>
    /// <returns></returns>
    TextCell NewTextCell(string text, double width,string textAlign);

    /// <summary>
    /// 获取新标题单元格对象
    /// </summary>
    /// <param name="text"></param>
    /// <returns></returns>
    TitleCell NewTitleCell(string text);

    /// <summary>
    /// 获取新的控件单元格
    /// </summary>
    /// <param name="key"></param>
    /// <param name="tabIndex"></param>
    /// <returns></returns>
    ControlCell NewControlCell(ExamDataElement dataElement, string key,double width,string tag,int tabIndex);

    PlaceholderCell NewPlaceholderCell(double width);



    /// <summary>
    /// 新的字段控件单元格
    /// </summary>
    public FieldControlCell NewFieldControlCell(string key, ExamDataElement examDataElement, double width, string tag, int tableIndex);


    /// <summary>
    /// 新的字段文字单元格
    /// </summary>
    public FieldTextCell NewFieldTextCell(string text, double width, int rowSpan, string textAlign);
}
